One type of random number generator uses a drifting oscillator, designed to have large phase jitter. If the oscillator output is sampled slowly enough, the sample values will be effectively random. An appropriate sampling rate must be utilized. If the sampling rate is too fast, the sample values will be mostly determined by the ratio of the oscillator frequency and the sample rate. If this ratio is not simple, as for example 2:1 or 3:5, the sample sequence will look random, but in fact it will be pseudo-periodic (meaning that the sequence deviates from a periodic one only in a few places, determined by the occasional above average noise levels in the circuit). Detecting this problem on-line, that is, with a simple circuit constantly analyzing the generated sample sequence, is difficult because a pseudo-period can be quite long, and so large buffers are necessary.
To avoid the problem of hard to detect low entropy, restart mode random number generators have been proposed. After each sample is taken from the output of the drifting oscillator, the oscillator is reset. The oscillator is always restarted from the same initial conditions. The result is larger randomness, because the drifting oscillator is more sensitive to noise in its start-up phase. In addition, instead of introducing pseudo-periodicity, sampling too fast causes long sequences of equal output bits to be generated.
Sampling too fast can result in mostly equal samples, because the accumulated jitter is not large enough to cause uncertainties at the sampling point. On-line randomness tests for restart mode random number generators (e.g., sampled drifting oscillators) have to detect long sequences of equal samples. Many currently used randomness tests (such as autocorrelation tests, poker tests, etc.) reliably detect a possible problem of this kind, but these tests are unnecessarily complex and expensive.